<template>
  <view class="notice-container">
    <!-- 遮罩层 -->
    <view class="mask" @click="closeNotice"></view>
    
    <!-- 须知内容弹窗 -->
    <view class="notice-popup">
      <text class="notice-title">入场须知</text>
      
      <view class="notice-content">
        <view class="notice-item">
          <text class="item-number">1.</text>
          <text class="item-text">请确保上传的进货清单包含商品名称、数量及农批市场签章</text>
        </view>
        
        <view class="notice-item">
          <text class="item-number">2.</text>
          <text class="item-text">营业执照需清晰展示执照编号与经营范围</text>
        </view>
        
        <view class="notice-item">
          <text class="item-number">3.</text>
          <text class="item-text">请准确选择入场时间，超时需重新预约</text>
        </view>
        
        <view class="notice-item">
          <text class="item-number">4.</text>
          <text class="item-text">入场核验码在预约入场时间后失效，请及时保存</text>
        </view>
        
        <view class="notice-item">
          <text class="item-number">5.</text>
          <text class="item-text">所有信息需真实有效，如有虚假将取消入场资格</text>
        </view>
      </view>
      
      <button class="confirm-btn" @click="closeNotice">我知道了</button>
    </view>
  </view>
</template>

<script>
export default {
  methods: {
    closeNotice() {
      // 关闭当前页面或返回上一页
      uni.navigateBack()
    }
  }
}
</script>

<style scoped>
.notice-container {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mask {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
}

.notice-popup {
  position: relative;
  width: 80%;
  max-width: 600rpx;
  background-color: #fff;
  border-radius: 20rpx;
  padding: 50rpx 40rpx 40rpx;
  z-index: 1001;
}

.notice-title {
  display: block;
  font-size: 36rpx;
  font-weight: bold;
  color: #333;
  text-align: center;
  margin-bottom: 40rpx;
}

.notice-content {
  margin-bottom: 50rpx;
}

.notice-item {
  display: flex;
  margin-bottom: 30rpx;
  line-height: 1.6;
}

.item-number {
  color: #ff8800;
  font-size: 32rpx;
  font-weight: bold;
  margin-right: 15rpx;
  flex-shrink: 0;
}

.item-text {
  flex: 1;
  font-size: 30rpx;
  color: #333;
}

.confirm-btn {
  width: 100%;
  height: 80rpx;
  background-color: #ff8800;
  color: #fff;
  font-size: 32rpx;
  font-weight: 500;
  border: none;
  border-radius: 40rpx;
  display: flex;
  align-items: center;
  justify-content: center;
}

.confirm-btn:active {
  opacity: 0.8;
}
</style>